package com.itheima.consumer.mq;

import lombok.extern.slf4j.Slf4j;
import org.junit.jupiter.api.Test;
import org.springframework.amqp.core.ExchangeTypes;
import org.springframework.amqp.rabbit.annotation.*;
import org.springframework.stereotype.Component;

import java.time.LocalTime;

@Slf4j
@Component
public class SpringRabbitListener2 {

    @RabbitListener(queues = "simple.queue")
    public void listenSimpleQueueMessages(String msg) {
        log.info("spring 消费者接收到消息:{}", msg);
    }

}